Skip to content

fix: Failing to delete multiple chat history together bug#956

Merged
Roopan-Microsoft merged 4 commits into
devfrom
KMC-HistoryDeleteAsh
Jun 10, 2026
Merged

fix: Failing to delete multiple chat history together bug#956
Roopan-Microsoft merged 4 commits into
devfrom
KMC-HistoryDeleteAsh

Conversation

@Ashwal-Microsoft

@Ashwal-Microsoft Ashwal-Microsoft commented Jun 10, 2026

Copy link
Copy Markdown
Contributor

This pull request improves the robustness and flexibility of the chat history deletion logic, especially for deployments that do not support bulk deletion. The main changes include adding pagination support to the history listing API and enhancing the "delete all history" function to fall back to deleting conversations individually if the bulk API is unavailable.

History listing improvements:

  • Added a limit parameter to the historyList API, allowing you to specify how many conversations to fetch per page. This enables paginated fetching of conversation history.

History deletion enhancements:

  • Updated the historyDeleteAll function to:
    • Attempt bulk deletion first.
    • If the bulk delete route is unavailable (e.g., returns a 404), fetch all conversation IDs in pages using the new limit parameter and delete them individually.
    • Aggregate the results and return an error if any individual deletions fail, otherwise return a success response.## Purpose
  • ...

Does this introduce a breaking change?

  • Yes
  • No

Golden Path Validation

  • I have tested the primary workflows (the "golden path") to ensure they function correctly without errors.

Deployment Validation

  • I have validated the deployment process successfully and all services are running as expected with this change.

What to Check

Verify that the following are valid

  • ...

Other Information

Prajwal-Microsoft and others added 4 commits May 26, 2026 07:46
refactor: dev to main - Foundry Roles and sanitize CU output for Unicode integrity
refactor: dev to main - Improve search index deletion logic and handling
chore: dev to main merge

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This pull request updates the frontend chat history APIs to better support paginated history listing and to make “clear all history” more resilient when a bulk-delete endpoint is unavailable.

Changes:

  • Added a limit parameter to historyList and sends it to /history/list for paginated fetching.
  • Enhanced historyDeleteAll to attempt bulk deletion first, and fall back to paginated listing + per-conversation deletion when the bulk route returns 404.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/App/src/api/api.ts
Comment thread src/App/src/api/api.ts
@Roopan-Microsoft Roopan-Microsoft merged commit 71e0a59 into dev Jun 10, 2026
76 of 85 checks passed
@github-actions

Copy link
Copy Markdown
Contributor

🎉 This PR is included in version 3.23.3 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants